package ${projectConfig.basePackage}.${config.model}.mapper.gen;

import ${projectConfig.beanPackage}.${config.model}.bean.po.gen.${config.objectName};
import ${projectConfig.beanPackage}.${config.model}.bean.po.gen.${config.objectName}Example;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Mapper;

@org.apache.ibatis.annotations.Mapper
public interface ${config.objectName}Mapper{
    int countByExample(${config.objectName}Example example);

    int deleteByExample(${config.objectName}Example example);
<#if (pks?size>0)>
    int deleteByPrimaryKey(<#list pks as prop>@Param("${prop.alias}") ${prop.javaType} ${prop.alias}<#if prop_has_next>,</#if></#list>);
</#if>
    int insert(${config.objectName} record);

    int insertSelective(${config.objectName} record);

    List<${config.objectName}> selectByExample(${config.objectName}Example example);
<#if (pks?size>0)>
    ${config.objectName} selectByPrimaryKey(<#list pks as prop>@Param("${prop.alias}") ${prop.javaType} ${prop.alias}<#if prop_has_next>,</#if></#list>);
</#if>
    int updateByExampleSelective(@Param("record") ${config.objectName} record, @Param("example") ${config.objectName}Example example);

    int updateByExample(@Param("record") ${config.objectName} record, @Param("example") ${config.objectName}Example example);
<#if (pks?size>0)>
    int updateByPrimaryKeySelective(${config.objectName} record);

    int updateByPrimaryKey(${config.objectName} record);
</#if>
}